import Layout from '@/views/Layout'
import Course from '@/views/Course'

const routes=[
    {
        path:"/",
        component:Layout,
        children:[
            {
                path:"/",
                name:"Home",
                component:Course
            },
            {
                path:"/course",
                name:"Course",
                component:Course
            },
            //新疆课程
            {
                path: '/courses/:courseId',
                name: 'CourseItem',
                component: () => import('../views/CourseItem.vue')
            },
            //
            {
                path:"/courses/:courseId/tasks",
                name:"CourseTasks",
                component:()=>import("../views/CourseTasks.vue")
            }
         ]
    },
    {
        path:"*",
        component:()=>import("../views/Error.vue")
    }
    
    
];

export default routes;
